package com.ruoyi.project.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.project.domain.entity.ProjectAttachment;
import com.ruoyi.project.domain.entity.ProjectParticipan;
import com.ruoyi.project.domain.query.ProjectFileQuery;
import com.ruoyi.project.domain.query.ProjectParticipanQuery;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface ProjectAttachmentMapper extends BaseMapper<ProjectAttachment> {
    List<ProjectAttachment> getList(ProjectFileQuery query);


    @Delete("DELETE FROM project_attachment WHERE project_no = #{projectNo} AND attachment_type = #{type}")
    void deleteHistory(@Param("projectNo") String projectNo, @Param("type") String type);

}
